package code.endpoint;

import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * @author 徐靖峰[OF2938]
 * company qianmi.com
 * Date 2018-04-25
 */
@RestController
@RequestMapping("/qq")
public class QQRestfulApiProviderController {

    @RequestMapping("/info/{qq}")
    public Map<String,Object> info(@PathVariable("qq") String qq){
        Map<String,Object> model = new HashMap<>();
        model.put("name","xiaoming");
        model.put("age",12);
        return model;
    }

    @RequestMapping("fans/{qq}")
    public Map<String,Object> fans(@PathVariable("qq") String qq){
        Map<String,Object> model = new HashMap<>();
        model.put("name","lissd");
        model.put("age",232323);
        return model;
    }

}
